package com.qianxp.designparttern.factory;
/**
 *@author qianxp
 */
public class TestMain {
    public static void main(String[] args) {
        AbstractFactory factory = new SimpleFactory();
        Person p1 = factory.getStudent();
        Person p2 = factory.getTeacher();
        p1.say();
        p1.run();
        p2.say();
        p2.run();
    }
}